1. Field
This disclosure relates generally to integrated circuits, and more specifically, to an apparatus and method for accessing a synchronous serial memory without knowing the size of the address bit field.
2. Related Art
Data processing systems can be found in many of today's electronic devices. Applications are wide ranging and include automotive, wireless, home appliances, etc. A typical data processing system includes a microprocessor that functions as a central processing unit (CPU). Most microprocessors (MPUs) and microcontrollers (MCUs) require “boot” code upon startup. Boot code is the software first accessed by the microprocessor to provide the initial instructions to start operating. Typically, boot code is stored in one of many types of nonvolatile memory. One type of nonvolatile memory used to store boot code is a synchronous serial memory.
Today, synchronous serial memories vary in size (number of bits or density) from 1 kilo bit (Kbit) up to 128 mega bits (Mbits). A different number of address bytes are required to access the synchronous serial memory depending on the memory's size. Generally, the number of address bytes increases as the memory density increases. For example, memory devices with densities from 1 to 4 Kbits, inclusive, require a single address byte (8 bits), and memory devices with densities from 8 to 256 Kbits require two address bytes. Therefore, when a read command is issued to the synchronous serial memory, the data processing system must “know” how many address bytes to provide. This variability in the number of address bytes makes it more difficult to, for example, upgrade a data processing system with a larger boot memory because the state machine and instructions used to access the memory must also be changed to account for the different number of address bytes.
One solution to the problem is to provide memory size information to the microprocessor using an additional pin or pins on the microprocessor. This would be a less than optimal use of such an additional pin as the memory is only accessed when the microprocessor is booted.
Another solution requires that the read opcode from the processor have as many bytes as the largest memory size supported. Smaller memories can use the larger number of address bytes if the initial data stored in the memory is zero-padded. However, this solution will not work for memories larger than the largest memory size supported.
Therefore, it would be desirable to have a system and method that solves the above problems.